#ifndef tutorialAnalysis_h
#define tutorialAnalysis_h

#include "baseAnalysis.hxx"
#include "AnaBoxB.hxx"
#include "AnalysisUtils.hxx"

class tutorialAnalysis: public baseAnalysis {
 public:
  tutorialAnalysis(AnalysisAlgorithm* ana=NULL);
  virtual ~tutorialAnalysis(){}

  //---- These are mandatory functions
  void DefineSelections();
  void DefineCorrections();
  void DefineSystematics();
  void DefineConfigurations();
  void DefineMicroTrees(bool addBase=true);
  void DefineTruthTree();

  bool Process();

  void FillMicroTrees(bool addBase=true);
  void FillToyVarsInMicroTrees(bool addBase=true);

  bool CheckFillTruthTree(const AnaTrueVertex& vtx);
  bool CheckFillRooTracker(const AnaTrueVertex& vtx);

  void FillTruthTree(const AnaTrueVertex& vtx);
  //--------------------

  void FillCategories();

public:

  enum enumStandardMicroTrees_tutorialAnalysis{
    nLongTPCTracks= enumStandardMicroTreesLast_baseAnalysis+1,
    selmu_truemom, 
    selmu_detectors,
    selmu_sense,
    selmu_theta,
    selmu_dir,
    selmu_pos,
    selmu_ntpcs,
    selmu_tpc_det,
    selmu_tpc_nnodes,
    selmu_tpc_mom,
    selmu_tpc_pos,
    selmu_tpc_dir,
    selmu_tpc_truemom,

    selmu_mom,
    selmu_tpc_dedx,

    truemu_truemom,
    truemu_truepos,
    truemu_truedir,
    truemu_truecostheta,
    enumStandardMicroTreesLast_tutorialAnalysis
  };


  enum enumSyst_tutorialAnalysis{
    kTutorialWeight = enumSystLast_baseAnalysis+1,
    kTutorialVariation,
    enumSystLast_tutorialAnalysis
  };

  enum enumConf_tutorialAnalysis{
    tutorial_syst=enumConfLast_baseAnalysis+1,
    enumConfLast_btutorialAnalysis
  };
  
};

#endif
